package com.wm.machine.baselibrary.utils.okhttp.exceptions;

/**
 * Copyright
 * author zhengcheng
 * date 2018/4/2
 * describe 对外统一的异常
 * history
 */

public class HttpApiException extends Exception{
    private String displayMessage;
    private int code;
    public HttpApiException(Throwable throwable, int code) {
        this.code = code;
    }

    @Override
    public String toString() {
        return "HttpApiException(code=" + code + ", displayMessage=" + displayMessage+ ")";
    }

    public String getDisplayMessage() {
        return displayMessage;
    }

    public void setDisplayMessage(String displayMessage) {
        this.displayMessage = displayMessage;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }
}
